package com.artpri.model;

import java.util.Date;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import static javax.persistence.GenerationType.IDENTITY;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 * AdPicture entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "ad_picture", catalog = "jpw")
public class AdPicture implements java.io.Serializable {

	// Fields

	private Integer apId;
	private String apPageName;
	private String apPositionName;
	private Integer apState;
	private String apPath;
	private String anAlt;
	private String apOldname;
	private String apUrl;
	private Integer apGoodNum;
	private Date apStart;
	private Date apStop;

	// Constructors

	/** default constructor */
	public AdPicture() {
	}

	/** minimal constructor */
	public AdPicture(String apPageName, String apPositionName, Integer apState,
			String apPath, String apOldname, String apUrl) {
		this.apPageName = apPageName;
		this.apPositionName = apPositionName;
		this.apState = apState;
		this.apPath = apPath;
		this.apOldname = apOldname;
		this.apUrl = apUrl;
	}

	/** full constructor */
	public AdPicture(String apPageName, String apPositionName, Integer apState,
			String apPath, String anAlt, String apOldname, String apUrl,
			Integer apGoodNum, Date apStart, Date apStop) {
		this.apPageName = apPageName;
		this.apPositionName = apPositionName;
		this.apState = apState;
		this.apPath = apPath;
		this.anAlt = anAlt;
		this.apOldname = apOldname;
		this.apUrl = apUrl;
		this.apGoodNum = apGoodNum;
		this.apStart = apStart;
		this.apStop = apStop;
	}

	// Property accessors
	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "ap_id", unique = true, nullable = false)
	public Integer getApId() {
		return this.apId;
	}

	public void setApId(Integer apId) {
		this.apId = apId;
	}

	@Column(name = "ap_page_name", nullable = false, length = 10)
	public String getApPageName() {
		return this.apPageName;
	}

	public void setApPageName(String apPageName) {
		this.apPageName = apPageName;
	}

	@Column(name = "ap_position_name", nullable = false, length = 10)
	public String getApPositionName() {
		return this.apPositionName;
	}

	public void setApPositionName(String apPositionName) {
		this.apPositionName = apPositionName;
	}

	@Column(name = "ap_state", nullable = false)
	public Integer getApState() {
		return this.apState;
	}

	public void setApState(Integer apState) {
		this.apState = apState;
	}

	@Column(name = "ap_path", nullable = false, length = 100)
	public String getApPath() {
		return this.apPath;
	}

	public void setApPath(String apPath) {
		this.apPath = apPath;
	}

	@Column(name = "an_alt", length = 50)
	public String getAnAlt() {
		return this.anAlt;
	}

	public void setAnAlt(String anAlt) {
		this.anAlt = anAlt;
	}

	@Column(name = "ap_oldname", nullable = false)
	public String getApOldname() {
		return this.apOldname;
	}

	public void setApOldname(String apOldname) {
		this.apOldname = apOldname;
	}

	@Column(name = "ap_url", nullable = false, length = 100)
	public String getApUrl() {
		return this.apUrl;
	}

	public void setApUrl(String apUrl) {
		this.apUrl = apUrl;
	}

	@Column(name = "ap_good_num")
	public Integer getApGoodNum() {
		return this.apGoodNum;
	}

	public void setApGoodNum(Integer apGoodNum) {
		this.apGoodNum = apGoodNum;
	}

	@Temporal(TemporalType.DATE)
	@Column(name = "ap_start", length = 10)
	public Date getApStart() {
		return this.apStart;
	}

	public void setApStart(Date apStart) {
		this.apStart = apStart;
	}

	@Temporal(TemporalType.DATE)
	@Column(name = "ap_stop", length = 10)
	public Date getApStop() {
		return this.apStop;
	}

	public void setApStop(Date apStop) {
		this.apStop = apStop;
	}

}